const getGoodsList = require("./getGoodsList/index");
const getGoodsDetail = require("./getGoodsDetail/index");
const addGoods = require("./addGoods/index");
const updateGoods = require("./updateGoods/index");
const exportGoods = require("./exportGoods/index");

// 云函数入口函数
exports.main = async (event, context) => {
    switch (event.type) {
        case "getGoodsList":
            return await getGoodsList.main(event, context);
        case "getGoodsDetail":
            return await getGoodsDetail.main(event, context);
        case "addGoods":
            return await addGoods.main(event, context);
        case "updateGoods":
            return await updateGoods.main(event, context);
        case "exportGoods":
            return await exportGoods.main(event, context);
    }
};